Multi-level RAID (redundant array of independent disks) storage arrays provide better performance and storage efficiency than single level RAID storage arrays by exploiting advantages of different RAID levels combined within the same array. Multi-level RAID arrays employ two or more RAID levels such as RAID level 1 and RAID level 5 that coexist on the same set of disks within the array. Generally, different RAID levels provide different benefits of performance versus storage efficiency. For example, RAID level 1 provides low storage efficiency because disks are mirrored for data redundancy, while RAID level 5 provides higher storage efficiency by creating and storing parity information on one disk that provides redundancy for data stored on a number of disks. However, RAID level 1 provides faster performance under random data writes than RAID level 5 because RAID level 1 does not require the multiple read operations that are necessary in RAID level 5 for recreating parity information when data is being updated (i.e. written) to a disk.
Multi-level RAID arrays migrate data between different RAID levels within the array to maximize the benefits of performance and storage efficiency offered by the different RAID levels. Generally, active data (i.e., data most recently written) is migrated from a lower performing RAID level to a higher performing RAID level, while inactive data (i.e., data least recently written) is migrated from a lower storage-efficient RAID level to a higher storage-efficient RAID level. Migration of data from a lower performance RAID level to a higher performance RAID level is called “promotion”. Migration of data from a higher performance RAID level to a lower performance RAID level is called “demotion”. Thus, for a multi-level RAID array employing RAID levels 1 and 5, for example, active data is promoted to RAID level 1 from RAID level 5, and inactive data is demoted from RAID level 1 to RAID level 5.
Although data migration between RAID levels in a multi-level RAID array generally helps to optimize performance and storage efficiency of the array, past methods of migrating data have several disadvantages. One disadvantage with past methods is that promotions are performed in the foreground while an array is servicing a write request. Foreground promotions inflate response times for a data write because the data write has to wait for the full promotion process to conclude before the data write can be considered finished.
A promotion (i.e., data migration) involves several operations. Assuming, for example, that a multi-level RAID array employs RAID level 1 and RAID level 5, the promotion process first requires that the block of data being updated by a data write be read from RAID level 5 (i.e., the slower performing RAID level) into memory on the array. The data write is then written to RAID level 1 (i.e., the faster performing RAID level). The size of the data block being promoted is typically much larger than the size of the original data write. Such foreground promotions, which include an extra read and write of the data block being promoted, incur a penalty that makes the service time for the data write much longer than it would be without the promotion. As mentioned in the previous paragraph, data write response times are inflated because the foreground promotion process has to wait for the extra read and write of a block of data that is typically larger than the size of the data write.
Another disadvantage with past methods of migrating data between RAID levels in a multi-level RAID array is that background demotions are not integrated with foreground promotions. Therefore, when a higher (i.e., faster) performing RAID level (e.g., RAID level 1) runs out of space, a promotion triggers a disruptive foreground demotion process to make space available in the higher performing RAID level by demoting data to a lower performing RAID level. Under these circumstances, the promotion process described above cannot take place until a demotion process occurs.
In an example demotion process, data is read from the higher performing RAID level 1 and merged into the block of data in memory that is to be written to the lower performing RAID level 5. The parity of the RAID level 5 block of data to be written is then computed, and the data block and the parity are written to RAID level 5. This process is called a “read, modify, write”. The size of the data block being demoted from RAID level 1 to RAID level 5 is typically much larger than the size of the original data write that instigated the demotion. Thus, the demotion process not only incurs time penalties for the “read, modify, write” process, but also incurs additional time penalties because the data block being demoted is typically larger in size than the original data write. Therefore, data write requests can result in response times that are orders of magnitude longer than would otherwise be necessary for a simple data write.
Accordingly, the need exists for a way to manage data in a multi-level RAID storage array that overcomes the penalties associated with current data migration methods and that optimally exploits advantages in performance and storage efficiency inherent to different RAID levels combined within an array.